package com.yy.QSManage.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.yy.QSManage.dao.FaSysRoleMenuMapper;
import com.yy.QSManage.model.entity.FaSysRoleMenu;
import com.yy.QSManage.service.FaSysRoleMenuService;
import com.yy.QSManage.service.base.impl.BaseServiceImpl;
import org.springframework.stereotype.Service;

@Service
public class FaSysRoleMenuServiceImpl extends BaseServiceImpl<FaSysRoleMenuMapper, FaSysRoleMenu> implements FaSysRoleMenuService{

    @Override
    public FaSysRoleMenu getMenuPower(String roleId, String menuId) {
        LambdaQueryWrapper<FaSysRoleMenu> lambda = new LambdaQueryWrapper<>();
        lambda.eq(FaSysRoleMenu::getRoleId, roleId)
                .eq(FaSysRoleMenu::getMenuId, menuId);
        return getOne(lambda);
    }
}

